package _04获取Class对象的三种方式;

import com.asin.domain.Person;
import com.asin.domain.Stu;

import java.lang.reflect.Field;

public class DemoGet {

    public static void main(String[] args) throws ClassNotFoundException {
        //1.方式一:类名.class
        Class<Person> personClass = Person.class;

        //2.方式二:对象名.getClass()
        Class<? extends Person> pclass = new Person().getClass();

        //3.方式三:Class.forName(类全名)
        Class<?> stuClass2 = Class.forName("com.asin.domain.Stu");


    }
}
